/**
 * Copyright © 2021 易久批信息技术有限公司. All rights reserved.
 */
package com.dysm.binarytree;

/**
 *
 * @author xiay
 * @since 2021/1/18 10:43 下午
 */
public class MyNode {

    private int value;

    private MyNode leftNode;

    private MyNode rightNode;

    public MyNode(int value, MyNode leftNode, MyNode rightNode) {
        this.value = value;
        this.leftNode = leftNode;
        this.rightNode = rightNode;
    }


    public int getValue() {
        return this.value;
    }

    public void setValue(int value) {
        this.value = value;
    }

    public MyNode getLeftNode() {
        return this.leftNode;
    }

    public void setLeftNode(MyNode leftNode) {
        this.leftNode = leftNode;
    }

    public MyNode getRightNode() {
        return this.rightNode;
    }

    public void setRightNode(MyNode rightNode) {
        this.rightNode = rightNode;
    }

    @Override
    public String toString() {
        return "MyNode{" +
                "value=" + value +
                ", leftNode=" + leftNode +
                ", rightNode=" + rightNode +
                '}';
    }
}
